﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace CheryABP.SystemSetting
{
    /// <summary>
    /// 分页Dto
    /// </summary>
    public class PageInputDto
    {
        public int _pageIndex = 1;
        /// <summary>
        /// 每页的数量
        /// </summary>
        [Required]
        public int pageSize { get; set; }

        /// <summary>
        /// 页码：第几页(>=0)
        /// </summary>
        [Required]
      
        public int pageIndex
        {
            get
            {
                if (_pageIndex < 1)
                {
                    return 0;
                }
                return _pageIndex-1;
            }
            set
            {
                _pageIndex = value;
            }
        }
    }
}
